<template>
  <div class="page-header col-xs-offset-2 col-xs-8">
    <h2>Vue路由测试</h2>
		<button @click="tui">←后退</button>
		<button @click="jin">前进→</button>
		<button @click="testGo">测试一下$router.go</button>
  </div>
</template>

<script>
	export default {
		name:'Header',
		mounted() {
			console.log('Header组件挂载了',this)
		},
		methods: {
			tui(){
				this.$router.back()
			},
			jin(){
				this.$router.forward()
			},
			testGo(){
				this.$router.go(3)
			}
		},		
	};
</script>